<script setup lang="ts">
definePageMeta({
  layout:'admin',
  title:'资金明细',
});
const form=reactive({
page:1,
limit:10,
});
const {data:list,refresh}=await useServerGet('/finance/getFlowList',form);
</script>

<template>
  <div>
    <el-card class="flex-1">

      <el-table :data="list.data.list"
        style="width: 100%"
        align="center">
        <el-table-column label="编号">
          <template #default="scope">{{ scope.row.id }}</template>
        </el-table-column>
        <el-table-column label="类型">
          <template #default="scope">{{ scope.row.type }}</template>
        </el-table-column>
        <el-table-column label="订单编号">
          <template #default="scope">{{ scope.row.order_id }}</template>
        </el-table-column>
        <el-table-column label="金额">
          <template #default="scope">{{ scope.row.money }}</template>
        </el-table-column>
        <el-table-column label="更新时间">
          <template #default="scope">{{ scope.row.updated_at }}</template>
        </el-table-column>
        <el-table-column label="创建时间">
          <template #default="scope">{{ scope.row.created_at }}</template>
        </el-table-column>
      </el-table>
      <MyPage v-model:page="form.page" v-model:perpage="form.limit" v-model:total="list.data.total" @change="refresh"></MyPage>
    </el-card>
  </div>

</template>

<style scoped lang="scss">
.border-right{
  &:last-child{
    border-right: none;
  }
  padding-left: 20px;
  border-right: 1px solid var(--el-border-color);
}
</style>